﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NUnit.Framework;
using Castle.MicroKernel;
using Castle.Windsor;

namespace MoqContrib.AutoMock.Castle.Tests
{
    public class TestHelper : AutoMockHelper, All.Tests.IDoAutoMockHelperStuff<TestContainer>
    {
        #region IDoAutoMockHelperStuff<TestContainer> Members

        public void InitializeDefault()
        {
            this.TestContainer = new TestContainer();
            Container = TestContainer;
        }

        public new TestContainer TestContainer { get; set; }

        public void AssertComponentNotFound<TService>() where TService : class
        {
            Assert.Throws<ComponentNotFoundException>(() => Container.Resolve<TService>());
        }

        #endregion
    }
}
